package com.adcc.ags.gms.mq.entity;

import com.adcc.ags.gms.core.entity.BaseEntity;

import java.util.Date;

/**
 * 队列实体
 */
public class Queue extends BaseEntity {

    //ID
    private Long id;

    // 名称
    private String name;

    // 类型
    private Integer type;

    // 队列优先级
    private Integer priority;

    // 持久化 0：非持久，1：持久
    private Integer persistent;

    // 最大队列深度
    private Integer maxDepth;

    // 最大消息长度
    private Integer maxMsgLength;

    // 保留时间间隔
    private Integer retainInterval;

    // 创建时间
    private Date createTime;

    // 生效按钮
    private String enable;

    /**
     * 构造函数
     */
    public Queue(){

    }

    /**
     * 构造函数
     * @param id
     */
    public Queue(Long id) {
        this.id = id;
    }

    /**
     * 构造函数
     */
    public Queue(String name){
        this.name = name;
    }

    /**
     * 构造函数
     * @param name
     * @param type
     */
    public Queue(String name, int type){
        this.name = name;
        this.type = type;
    }

    /**
     * 构造函数
     * @param name
     * @param type
     * @param priority
     */
    public Queue(String name, int type, int priority){
        this.name = name;
        this.type = type;
        this.priority = priority;
    }

    /**
     * 构造函数
     * @param name
     * @param type
     * @param priority
     * @param persistent
     */
    public Queue(String name, int type, int priority, int persistent){
        this.name = name;
        this.type = type;
        this.priority = priority;
        this.persistent = persistent;
    }


    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public Integer getPriority() {
        return priority;
    }

    public void setPriority(Integer priority) {
        this.priority = priority;
    }

    public Integer getPersistent() {
        return persistent;
    }

    public void setPersistent(Integer persistent) {
        this.persistent = persistent;
    }

    public Integer getMaxDepth() {
        return maxDepth;
    }

    public void setMaxDepth(Integer maxDepth) {
        this.maxDepth = maxDepth;
    }

    public Integer getMaxMsgLength() {
        return maxMsgLength;
    }

    public void setMaxMsgLength(Integer maxMsgLength) {
        this.maxMsgLength = maxMsgLength;
    }

    public Integer getRetainInterval() {
        return retainInterval;
    }

    public void setRetainInterval(Integer retainInterval) {
        this.retainInterval = retainInterval;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public String getEnable() {
        return enable;
    }

    public void setEnable(String enable) {
        this.enable = enable;
    }
}
